import { Module } from "@nestjs/common";
import { UserController } from "../controller/user.controller";
import { UserRegisterService } from "../service/user/user.register.service";
import { UserExistService } from "../service/user/user.exist.service";
import { PassportModule } from "@nestjs/passport";
import { JwtModule } from "@nestjs/jwt";
import { jwtConstants } from "../service/auth/constants";
import { AuthService } from "../service/auth/auth.service";
import { JwtStrategy } from "../service/auth/jwt.strategy";

@Module({
  controllers: [UserController],
  imports: [UserModule,
    PassportModule,
    JwtModule.register({
      secret: jwtConstants.secret,
      signOptions: { expiresIn: '24h' },
    }),
  ],
  providers: [UserExistService,UserRegisterService,AuthService,JwtStrategy],
  exports: [UserExistService, UserRegisterService,AuthService,],
})
export class UserModule {
}
